	
	<?php echo validation_errors(); ?>
	
	<form id="customForm" method="post" action="<?php echo site_url()?>/user/new_user2">
		
		<input type="hidden" id="id" name="user_form[id]" value="<?php if(isset($id)) echo $id?>" />
		
		
		<label><?php echo lang('form_label_username')?></label>
		<input type="text" id="username" name="user_form[username]" value="<?php echo set_value('username'); if(isset($username)) echo $username?>" />
		
		
		<label><?php echo lang('form_label_email')?></label>
		<input type="text" id="email" name="user_form[email]" value="<?php echo set_value('email'); if(isset($email)) echo $email?>" />
		
		<label><?php echo lang('general_1stname')?></label>
		<input type="text" id="first_name" name="user_form[first_name]" value="<?php echo set_value('first_name'); if(isset($first_name)) echo $first_name?>" />
		
		<label><?php echo lang('general_lastname')?></label>
		<input type="text" id="lastname" name="user_form[last_name]" value="<?php echo set_value('last_name'); if(isset($last_name)) echo $last_name?>" />

		<label><?php echo lang('form_label_password')?></label>
		<input type="password" id="password" name="user_form[password]" value="" />

		<label><?php echo lang('form_label_confpassword')?></label>
		<input type="password" id="passconf" name="passconf" value="" />
		
		<label><?php echo lang('general_type')?></label>

		<select id="type_id" name="user_form[type_id]">
			<option value='a'> <?php echo "-- ".lang('menuitem_select')." --"?></option>
			<?php
				foreach($staff_type as $id => $value){
					if($id == $type_id)
						echo "<option selected='selected' value='".$id."' ". set_select('user_form[type_id]', $id) ." >".$value."</option>";
					else
						echo "<option value='".$id."' ". set_select('user_form[type_id]', $id) ." >".$value."</option>";
				}
			?>
		</select>

		<label><?php echo lang('menuitem_specialities')?></label>
		<select id="user_form[specialty_id]" name="user_form[specialty_id]">
			<option  value='a'><?php echo "-- ".lang('menuitem_select')." --"?></option>
			<?php
				foreach($specialty as $id => $value){
					if($id == $specialty_id)
						echo "<option selected='selected' value='".$id."' ". set_select('user_form[specialty_id]', $id) .">".$value."</option> ";
					else
						echo "<option value='".$id."' ". set_select('user_form[specialty_id]', $id) .">".$value."</option> ";
				}
			?>
		</select>

		
		<input type="submit" id="submit" name="submit" value="<?php echo lang('form_label_save')?>" />
	</form>
